<!--<include file="public+header" />-->

<!--{~$sCalendarLang=Core_Extend::calendar()}-->
<script type="text/javascript" src="<!--{:__PUBLIC__}-->/js/calendar/datepicker/WdatePicker.js"></script>
<script src="<!--{:__PUBLIC__}-->/js/jquery/imagepreview/jquery.imagepreview.js" type="text/javascript"></script>

<!--{script}-->
$(function(){
	$("a.preview").preview();
});
<!--{/script}-->

<!--{style}-->
html{overflow-y:scroll;}
a.preview,a.preview:hover{text-decoration:none;}
a.preview img{margin:10px 5px;}
<!--{/style}-->

	<section class="secondary_bar">
		<div class="breadcrumbs_container">
			<article class="breadcrumbs"><a href="<!--{:Q::U('public/fmain')}-->"><!--<lang package='Template'>-->主页<!--</lang>--></a> <div class="breadcrumb_divider"></div> <a class="current"><!--<lang package='Template'>-->多媒体列表<!--</lang>--></a> <div class="breadcrumb_divider"></div> <a href="javascript:void(0);" onclick="adminctrlmenuAdd('<!--{:__SELF__}-->','<!--<lang package='Template'>-->多媒体列表<!--</lang>-->')" title="<!--<lang package='Template'>-->添加到快捷导航<!--</lang>-->">[+]</a></article>
		</div>
	</section>

	<section id="main" class="column">
		<article class="module width_full">
			<header><h3><!--<lang package='Template'>-->操作提示<!--</lang>--></h3></header>
			<div class="module_content">
				<ul>
					<li><!--<lang package='Template'>-->这里对多媒体进行统一管理<!--</lang>--></li>
				</ul>
			</div>

			<div class="module_content">
				<form method='get' action="<!--{:Q::U( 'attachment/index' )}-->" class="quick_search">
					<table cellspacing="3" cellpadding="3">
						<tr>
							<th><!--<lang package='Template'>-->多媒体类型<!--</lang>--></th>
							<td><input type="text" name="attachment_extension" title="<!--<lang package='Template'>-->多媒体类型<!--</lang>-->" value="<!--{:Q::G('attachment_extension')}-->"></td>
							<th><!--<lang package='Template'>-->结果排序<!--</lang>--></th>
							<td>
								<select name="order_">
									<option value="" <!--{if !Q+G('order_')}-->selected<!--{/if}-->><!--<lang package='Template'>-->排序字段<!--</lang>--></option>
									<option value="attachment_id" <!--{if Q+G('order_')=='attachment_id'}-->selected<!--{/if}-->><!--<lang package='Template'>-->编号<!--</lang>--></option>
									<option value="create_dateline" <!--{if Q+G('order_')=='create_dateline'}-->selected<!--{/if}-->><!--<lang package='Template'>-->添加时间<!--</lang>--></option>
								</select>
								<select name="sort_">
									<option value="" <!--{if !Q+G('sort_')}-->selected<!--{/if}-->><!--<lang package='Template'>-->默认排序<!--</lang>--></option>
									<option value="desc" <!--{if Q+G('sort_')=='desc'}-->selected<!--{/if}-->><!--<lang package='Template'>-->递增<!--</lang>--></option>
									<option value="asc" <!--{if Q+G('sort_')=='asc'}-->selected<!--{/if}-->><!--<lang package='Template'>-->递减<!--</lang>--></option>
								</select>
								<select name="perpage">
									<option value="" <!--{if !Q+G('perpage')}-->selected<!--{/if}-->><!--<lang package='Template'>-->默认每页数量<!--</lang>--></option>
									<option value="10" <!--{if Q+G('perpage')==10}-->selected<!--{/if}-->><!--<lang package='Template'>-->每页数量<!--</lang>-->(10)</option>
									<option value="20" <!--{if Q+G('perpage')==20}-->selected<!--{/if}-->><!--<lang package='Template'>-->每页数量<!--</lang>-->(20)</option>
									<option value="50" <!--{if Q+G('perpage')==50}-->selected<!--{/if}-->><!--<lang package='Template'>-->每页数量<!--</lang>-->(50)</option>
									<option value="100" <!--{if Q+G('perpage')==100}-->selected<!--{/if}-->><!--<lang package='Template'>-->每页数量<!--</lang>-->(100)</option>
									<option value="200" <!--{if Q+G('perpage')==200}-->selected<!--{/if}-->><!--<lang package='Template'>-->每页数量<!--</lang>-->(200)</option>
									<option value="500" <!--{if Q+G('perpage')==500}-->selected<!--{/if}-->><!--<lang package='Template'>-->每页数量<!--</lang>-->(500)</option>
								</select>
							</td>
						</tr>
						<tr>
							<th><!--<lang package='Template'>-->所属专辑<!--</lang>-->(ID)</th>
							<td><input type="text" name="attachmentcategory_id" title="<!--<lang package='Template'>-->所属专辑<!--</lang>-->" value="<!--{:Q::G('attachmentcategory_id')}-->" onkeyup="this.value = this.value.replace(/[^-0-9]/g,'');" /></td>
							<th><!--<lang package='Template'>-->添加时间<!--</lang>--></th>
							<td>
								<input type="text" id="start_time" name="start_time" value="<!--{:Q::G('start_time')}-->" onfocus="WdatePicker({el:'start_time',skin:'ext',lang:'<!--{$sCalendarLang}-->',dateFmt:'yyyy-MM-dd'})">
								&nbsp;~&nbsp;
								<input type="text" id="end_time" name="end_time" value="<!--{:Q::G('end_time')}-->"  onfocus="WdatePicker({el:'end_time',skin:'ext',lang:'<!--{$sCalendarLang}-->',dateFmt:'yyyy-MM-dd'})">
							</td>
						</tr>
						<tr>
							<th><!--<lang package='Template'>-->上传用户<!--</lang>--></th>
							<td><input type="text" name="attachment_username" title="<!--<lang package='Template'>-->上传用户<!--</lang>-->" value="<!--{:Q::G('attachment_username')}-->" onkeyup="this.value = this.value.replace(/[^-0-9]/g,'');" /></td>
							<th>UID</th>
							<td><input type="text" name="user_id" title="UID" value="<!--{:Q::G('user_id')}-->" onkeyup="this.value = this.value.replace(/[^-0-9]/g,'');" /></td>
						</tr>
						<tr>
							<th><!--<lang package='Template'>-->编号<!--</lang>--></th>
							<td><input type="text" name="attachment_id" title="<!--<lang package='Template'>-->编号<!--</lang>-->" value="<!--{:Q::G('attachment_id')}-->" onkeyup="this.value = this.value.replace(/[^-0-9]/g, '');" />
							</td>
							<td colspan="2">
								<input type="text" name="attachment_name" title="<!--<lang package='Template'>-->多媒体名字<!--</lang>-->" value="<!--{:Q::G('attachment_name')}-->" class="quicksearch_text">
								&nbsp;<input type="submit" id="" value="<!--<lang package='Template'>-->查询<!--</lang>-->" onclick="" class="alt_btn">
							</td>
						</tr>
					</table>
					<input type="hidden" name="c" value="<!--{:MODULE_NAME}-->"/>
					<input type="hidden" name="a" value="<!--{:ACTION_NAME}-->"/>
				</form>
			</div>
		</article>
		
		<article class="module width_full">
			<header><h3 class="tabs_involved"><a href="<!--{:Q::U('attachment/index')}-->"><!--<lang package='Template'>-->多媒体列表<!--</lang>--></a></h3>
				<ul class="tabs">
					<!--{if isset($sType)}-->
					<li><a href="<!--{:Q::U('attachment/index?type='.$sType)}-->"><!--<lang package='Template'>-->多媒体类型<!--</lang>-->&nbsp;(<!--{$sType}-->)</a></li>
					<!--{/if}-->
					<!--{if isset($arrAttachmentcategory)}-->
					<li><a href="<!--{:Q::U('attachment/index?cid='.$arrAttachmentcategory[1])}-->"><!--<lang package='Template'>-->专辑<!--</lang>-->&nbsp;(<!--{$arrAttachmentcategory[0]}-->)</a></li>
					<!--{/if}-->
					<!--{if isset($oUser)}-->
					<li><a href="<!--{:Q::U('attachment/index?uid='.$oUser['user_id'])}-->"><!--<lang package='Template'>-->用户<!--</lang>-->&nbsp;(<!--{$oUser['user_name']}-->)</a></li>
					<!--{/if}-->
					<li><a href="<!--{:Q::U('attachmentcomment/index')}-->"><!--<lang package='Template'>-->多媒体评论列表<!--</lang>--></a></li>
					<li class="active"><a href="<!--{:Q::U('attachmentcategory/index')}-->"><!--<lang package='Template'>-->多媒体专辑列表<!--</lang>--></a></li>
					<li><a class="tab_add" href="javascript:void(0);" onclick="add()"><!--<lang package='Template'>-->新增<!--</lang>--></a></li>
					<li><a class="tab_edit" href="javascript:void(0);" onclick="edit()"><!--<lang package='Template'>-->编辑<!--</lang>--></a></li>
					<li><a class="tab_delete" href="javascript:void(0);" onclick="foreverdelDeep()"><!--<lang package='Template'>-->彻底删除<!--</lang>--></a></li>
				</ul>
			</header>
			<div class="module_content">
				<table class="tablesorter" cellspacing="0" id="checkList">
					<thead>
						<tr>
							<th width="20px"><input type="checkbox" onclick="checkAll('checkList')"></th> 
							<th width="85px"><a href="javascript:sortBy('attachment_id','<!--{$sSortByUrl}-->')" <!--{:Admin_Extend::sortField('attachment_id')}-->><!--<lang package='Template'>-->编号<!--</lang>--></a></th>
							<th width="48px"><!--<lang package='Template'>-->预览<!--</lang>--></th>
							<th><a href="javascript:sortBy('attachment_name','<!--{$sSortByUrl}-->')" <!--{:Admin_Extend::sortField('attachment_name')}-->><!--<lang package='Template'>-->多媒体名字<!--</lang>--></a></th>
							<th width="90px"><a href="javascript:sortBy('user_id','<!--{$sSortByUrl}-->')" <!--{:Admin_Extend::sortField('user_id')}-->><!--<lang package='Template'>-->上传用户<!--</lang>--></a></th>
							<th width="150px"><a href="javascript:sortBy('attachmentcategory_id','<!--{$sSortByUrl}-->')" <!--{:Admin_Extend::sortField('attachmentcategory_id')}-->><!--<lang package='Template'>-->所属专辑<!--</lang>--></a></th>
							<th width="110px"><a href="javascript:sortBy('attachment_extension','<!--{$sSortByUrl}-->')" <!--{:Admin_Extend::sortField('attachment_extension')}-->><!--<lang package='Template'>-->多媒体类型<!--</lang>--></a></th>
							<th width="90px"><a href="javascript:sortBy('attachment_size','<!--{$sSortByUrl}-->')" <!--{:Admin_Extend::sortField('attachment_size')}-->><!--<lang package='Template'>-->多媒体大小<!--</lang>--></a></th>
							<th width="90px"><a href="javascript:sortBy('attachment_commentnum','<!--{$sSortByUrl}-->')" <!--{:Admin_Extend::sortField('attachment_commentnum')}-->><!--<lang package='Template'>-->评论次数<!--</lang>--></a></th>
							<th width="100px"><a href="javascript:sortBy('create_dateline','<!--{$sSortByUrl}-->')" <!--{:Admin_Extend::sortField('create_dateline')}-->><!--<lang package='Template'>-->添加时间<!--</lang>--></a></th>
							<th width="40px"><!--<lang package='Template'>-->操作<!--</lang>--></th>
						</tr>
					</thead>
					<tbody>
						<!--{if !empty($arrLists)}-->
						<!--<foreach for=arrLists>-->
						<tr id="datalist-<!--{$value.attachment_id}-->">
							<td><input type="checkbox" name="key" value="<!--{$value.attachment_id}-->"></td>
							<td><!--{$value.attachment_id}--></td>
							<td><a href="<!--{:Attachment_Extend::getAttachmenturl($value)}-->" target="_blank" <!--{if in_array($value['attachment_extension'],array('png','jpg','jpeg','gif','bmp'))}-->class="preview"<!--{/if}--> title="<!--{$value.attachment_name}-->"><img src="<!--{:Attachment_Extend::getAttachmentPreview($value)}-->" width="46" height="60"></a></td>
							<td><a href="<!--{:Attachment_Extend::getAttachmenturl($value)}-->" target="_blank"<!--{if in_array($value['attachment_extension'],array('png','jpg','jpeg','gif','bmp'))}-->class="preview"<!--{/if}--> title="<!--{$value.attachment_name}-->"><!--{$value.attachment_name}--></a>
								<div class="row-actions">
									<!--{if $value['attachment_isimg']==1 && $value['attachmentcategory_id']>0}-->
									<span class='view'><a href="<!--{:Q::U('attachment/cover?id='.$value['attachment_id'])}-->"><!--<lang package='Template'>-->封面<!--</lang>--></a>|</span>
									<!--{/if}-->
									<span class='view'><a href="<!--{:Core_Extend::windsforceOuter('app=home&c=attachment&a=show&id='.$value['attachment_id'])}-->" target="_blank"><!--<lang package='Template'>-->查看<!--</lang>--></a>|</span>
									<span class='edit'><a href="javascript:edit('<!--{$value.attachment_id}-->')"><!--<lang package='Template'>-->编辑<!--</lang>--></a>|</span>
									<span class='delete'><a href="javascript:foreverdelDeep('<!--{$value.attachment_id}-->');"><!--<lang package='Template'>-->彻底删除<!--</lang>--></a></span>
								</div>
							</td>
							<td><a href="<!--{:Q::U('attachment/index?uid='.$value['user_id'])}-->"><!--{$value['user_name']}--></a></td>
							<td><!--{if $value['attachmentcategory_id']>0}-->
								<a href="<!--{:Q::U('attachment/index?cid='.$value['attachmentcategory_id'])}-->"><!--{$value['attachmentcategory_name']}-->&nbsp;(<!--{$value['attachmentcategory_attachmentnum']}-->)</a>
								<!--{d*else}--><!--<lang package='Template'>-->默认专辑<!--</lang>-->
								<!--{/if}-->
							</td>
							<td><a href="<!--{:Q::U('attachment/index?type='.$value['attachment_extension'])}-->"><!--{$value.attachment_extension}--></a></td>
							<td><!--{$value['attachment_size']|C+changeFileSize}--></td>
							<td><!--{$value.attachment_commentnum}--></td>
							<td><span class="<!--{:Admin_Extend::dateColor($value['create_dateline'])}-->"><!--{$value['create_dateline']|date='Y-m-d',**}--></span><br/>
								<span class="smallDatecolor"><!--{$value['create_dateline']|date='H:i',**}--></span>
							</td>
							<td><a href="javascript:edit('<!--{$value.attachment_id}-->')"><input type="image" src="<!--{:At::path('icn_edit.png')}-->" title="<!--<lang package='Template'>-->编辑<!--</lang>-->"></a>
							</td>
						</tr>
						<!--</foreach>-->
						<!--{d*else}-->
						<tr>
							<td colspan="13"><!--<lang package='Template'>-->暂时没有发现任何记录<!--</lang>--></td>
						</tr>
						<!--{/if}-->
					</tbody>
				</table>
			</div>

			<div class="module_content operate_box">
				<div class="left">
					<!--{$sPageNavbar}-->
				</div>
				<div class="right operate" style="text-align:right;">
					<input type="button" name="add" value="<!--<lang package='Template'>-->新增<!--</lang>-->" onclick="add()" class="alt_btn">&nbsp;
					<input type="button" name="edit" value="<!--<lang package='Template'>-->编辑<!--</lang>-->" onclick="edit()" class="alt_btn">&nbsp;
					<input type="button" name="delete" value="<!--<lang package='Template'>-->彻底删除<!--</lang>-->" onclick="foreverdelDeep()" class="alt_btn">
				</div>
				<div class="clearfix"></div>
			</div>
		</article>

<!--<include file="public+footer">-->